{include file="header"}
<style>
    .layui-btn-danger{
        margin-left: 0;
    }
</style>
<div class="x-nav">
          <span class="layui-breadcrumb">
            <a href="">{:lang("system")}</a>
            <a href="">{:lang("user")}</a>
            <a>
              <cite>{:lang("user.log")}</cite></a>
          </span>
    <a class="layui-btn layui-btn-small" style="line-height:1.6em;margin-top:3px;float:right" onclick="location.reload()" title="{:lang('refresh')}">
        <i class="layui-icon layui-icon-refresh" style="line-height:30px"></i></a>
</div>
<div class="layui-fluid">
    <div class="layui-row layui-col-space15">
        <div class="layui-col-md12">
            <div class="layui-card">
                <div class="layui-card-header">
                    <button class="layui-btn layui-btn-danger" onclick="del()"><i class="layui-icon">&#xe640;</i>清空</button>
                </div>
                <div class="layui-card-body">
                    <table class="layui-table layui-form">
                        <thead>
                        <tr>
                            <th>{:lang('action')}{:lang('name')}</th>
                            <th>{:lang('action')}{:lang('Module')}</th>
                            <th>{:lang('administrator')}{:lang('name')}</th>
                            <th>提交参数</th>
                            <th>{:lang('return')}{:lang('result')}</th>
                            <th>{:lang('add')}{:lang('datetime')}</th>
                        </tr>
                        </thead>
                        <tbody>
                        {volist name="lists" id="item"}
                        <tr class="tr_{$item.id}">
                            <td>{$item.action}</td>
                            <td>{$item.action_name}</td>
                            <td>{$item.user_name}</td>
                            <td>{$item.content}</td>
                            <td>{$item.response}</td>
                            <td>{$item.add_time}</td>
                        </tr>
                        {/volist}
                        </tbody>
                    </table>
                </div>
                <div class="layui-card-body ">
                    {$lists|raw}
                </div>
            </div>
        </div>
    </div>
</div>

{include file="footer"}
<script>
    function del() {
        layer.confirm("{:lang('del.confirm')}",{icon: 3, title:'{:lang("tips")}'},function (index) {
            layer.close(index);
            request("POST",'{:url("user/logdel")}',{},function (res) {
                window.location.href="{:url('user/log')}";
            })

        })
    }

</script>